DeleteFrameSheet
DeleteFrameSheet FrameSheet
 
Parameters:

    FrameSheet = The Frame Sheet you wish to delete
Returns: NONE
 

     DeleteFrameSheet removes the frame sheet and all the frame images it contained from memory.



FACTS:


      * Once a frame sheet is deleted, any animations that are still using, will no longer be valid.

 
Example Source: Download This Example
; include the frame sheet animation library
  #Include "FrameSheetAnims"
  
  
; The file name of the example frame sheet we're going
; to load
  Filename$=ProgramDir$()+"Help/Commands/Media/Animations/explosions.png"
  
; Load the Frame sheet
  FrameSheet=LoadFrameSheet(Filename$,64,64,RGB(0,0,0))
  
; display the status of this frame sheet
; (1= exist, 0 it doesn't)
  Print "Status:"+Str$(GetFrameSheetStatus(FrameSheet))
  
  
; Display the number of frames in this sheet
  Print GetFrameSheetCount(FrameSheet)
  
  
; Draw the frames on the screen
  Ypos=100
  CenterText 400,Ypos-20,"Frames This in frame sheet"
  
; run through this frame sheet and draw each frame to the screen
  For lp=0 To GetFrameSheetCount(FrameSheet)-1
     ThisIMage=GetFrameSheetImage(FrameSheet,lp)
     DrawImage ThisImage,Xpos,Ypos,false
     Width=GetImageWidth(thisImage)
     Xpos+=Width
     If (Xpos+Width)=>GetScreenWidth()
        Xpos=0
        Ypos+=GetImageHeight(thisImage)
     EndIf
  Next
  
  
; Delete the Frame Sheet
  DeleteFrameSheet(FrameSheet)
  
; display the status of this frame sheet
; (1= exist, 0 it doesn't)
  Print "Status:"+Str$(GetFrameSheetStatus(FrameSheet))
  
; show the screen to the user and wait for a key press
  Sync
  WaitKey
  
 
Related Info: GetFrameSheetStatus | LoadFrameSheet :
 


(c) Copyright 2002 - 2024 - Kevin Picone - PlayBASIC.com